From beb73ea86225bfeeddbb2ab2783ade1a8ba33225 Mon Sep 17 00:00:00 2001 From: =?utf8?q?G=C3=B6ran=20Uddeborg?= Date: Mon, 30 Nov 2015 18:11:57 +0100 Subject: [PATCH] Declare the xstrdup(const char*) variant of xstrdup. Previously, only the xstrdup(const Qstring&) version was known, which led to incorrect encoding conversions. https://sourceforge.net/p/gpsbabel/mailman/gpsbabel-misc/thread/22100.54710.435238.946764%40mimmi.uddeborg/#msg34645421 --- defs.h | 1 + 1 file changed, 1 insertion(+) diff --git a/defs.h b/defs.h index 9a8cf0391..7c9a39f88 100644 --- a/defs.h +++ b/defs.h @@ -902,6 +902,7 @@ char* xstrappend(char* src, const char* addon); #define xxrealloc(p, s, file, line) xrealloc(p,s) #define xxfree(mem, file, line) xfree(mem) #define xxstrdup(s, file, line) xstrdup(s) +char *xstrdup(const char* s); #define xxstrappend(src, addon, file, line) xstrappend(src, addon) #else /* DEBUG_MEM */ void* XCALLOC(size_t nmemb, size_t size, DEBUG_PARAMS); -- 2.30.2